﻿using System;
using System.Collections.Generic;
using System.Data.Common;

namespace YJKDataBase
{
	public interface IObjectTable
	{
		bool Add(DbCategory category, DbObject dbObject, DbTransaction tr);

		bool Remove(DbObject dbObject, DbTransaction tr);

		bool Update(DbObject dbObject);

		void ReDateByNow(DbObject dbObject);

		DbObject this[Guid id]
		{
			get;
		}

		DbObject this[string name]
		{
			get;
		}

		List<DbObject> this[Parent parent]
		{
			get;
		}

		List<DbObject> this[Parent parent, int start, int end]
		{
			get;
		}

		int Count(Parent parent);

		int Count();

		List<DbObject> GetAll();

		List<DbObject> SearchFamily(string familyName);
	}
}
